<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="../jquery-3.1.1.js"></script>
</head>

<body>
    <input name="none1" value="none1" />
    <form>
        <label>姓名:</label>
        <input name="name" />
        <label>通讯:</label>
        <input name="newsletter" />
    </form>
    <input class="cls1" name="none2" value="none2" />
    <input class="cls1" name="none3" value="none3" />
    <input id="none4" class="cls1" name="none4" value="none4" />
    <input name="none5" value="none5" />
</body>
<script>
    $(function() {
        let inputt = $('body>input')
        let frominputt = $('form >input')
        let fromtongbeiinputt = $('form~input')
        let fromjinaiinputt = $('form+input')
        let class1 = $('input[class=cls1]')
        let id5 = $('input[id=none5]')
        let body1 = $('body input:first-child')

        console.log(inputt)
        console.log(frominputt)
        console.log(fromtongbeiinputt)
        console.log(fromjinaiinputt)
        console.log(class1)
        console.log(id5)
        console.log(body1)
    })

   
</script>

</html>